package com.dragon.pear.pages.common.main;

import com.dragon.pear.R;
import com.dragon.pear.common.utils.InjectUtil;
import com.chris.libs.base.x.mvpp.activity.BaseMvppActivity;

import javax.inject.Inject;

public class MainActivity extends BaseMvppActivity {
    @Inject
    MainViewProxy viewProxy;

    @Override
    public void doInject() {
        InjectUtil.create().inject(this);
    }

    @Override
    public int layoutId() {
        return R.layout.act_main;
    }

    @Override
    public void doProxy() {
        // 绑定视图代理
        this.viewProxy.bind(this);
        // 添加试图代理的生命周期托管
        this.observer = viewProxy;
        addObserver(this.observer);
    }
}
